<?php

/**
 * @Description    岗位验证
 * @Author         Luobo
 * @Copyright      山东艾思软件科技有限公司(https://www.aisisofit.cn)
 * @Date           2022-5-13
 * @CreateBy       vs code
 */

namespace app\core\validate;

use think\Validate;

class CoreTitle extends Validate {

    protected $rule = [
        'name'  => 'require|unique:core_title|max:50',
        'level' => 'require|max:50',
        'sort'  => 'number|between:0,99999',
    ];

    protected $message = [
        'name.require'   => '请输入岗位名称',
        'name.max'       => '岗位名称不能超过50个字符',
        'name.unique'    => '该岗位名称已经存在',
        'sort.number'    => '排序字段必须是个整数',
        'level.require'  => '请输入岗位级别',
        'level.max'      => '岗位级别不能超过50个字符',
    ];
}
